package com.apps.member.account.model.po;

import java.math.BigDecimal;

import com.apps.member.account.enums.AccountFrozenItemMinType;
import com.apps.member.account.enums.AccountFrozenItemType;
import com.apps.sannotation.constraints.NoNull;
import com.apps.sannotation.constraints.NumDef;
import com.apps.sannotation.constraints.StrDef;
import com.apps.sannotation.constraints.StrEnums;
import com.apps.sannotation.identity.AccountId;
import com.apps.sannotation.identity.GmtCreate;
import com.apps.sannotation.identity.GmtModify;
import com.apps.sannotation.identity.MemberId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import java.time.LocalDateTime;
import java.io.Serializable;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

/**
 * <p>
 * 
 * </p>
 *
 * @author 大鹏
 * @since 2020-10-13
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("kupa_account_frozen_item")
public class KupaAccountFrozenItem implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @MemberId
    private Integer member_id;
    @AccountId
    private Integer account_id;

    /**
     * 冻结类型
     */
    @NoNull
    @StrEnums(enums = AccountFrozenItemType.class)
    private String type;

    @NoNull
    @StrEnums(enums = AccountFrozenItemMinType.class)
    private String type_min;

    /**
     * 冻结金额
     */
    @NumDef(value = 0,Cla = BigDecimal.class)
    private BigDecimal price;

    @GmtCreate
    private LocalDateTime gmt_create;
    @GmtModify
    private LocalDateTime gmt_modify;
    @StrDef("")
    private String remark;


    public static final String ID = "id";

    public static final String MEMBER_ID = "member_id";

    public static final String ACCOUNT_ID = "account_id";

    public static final String TYPE = "type";

    public static final String PRICE = "price";

    public static final String STATUS = "status";

    public static final String GMT_CREATE = "gmt_create";

    public static final String GMT_MODIFY = "gmt_modify";

    public static final String REMARK = "remark";

}
